#pragma once
#include "DXAMLCommon.h"

#include "XamlParserFrame.h"


class XamlParserStack
{
public: 
	HRESULT PushScope(const xshared_ptr<xstringmap<xshared_ptr<XamlNamespace> > > & prescopeNamespaces);
	HRESULT PopScope();
	XBOOL IsEmpty() const;
	XamlParserFrame & Top();
	const XamlParserFrame & Top() const;
	HRESULT FindNamespaceByPrefix(const xshared_ptr<CXString> & inPrefix, xshared_ptr<XamlNamespace> & outNamespace) const;
private: 
	xstack<XamlParserFrame> m_Stack;
private: 
	xvector<XamlParserFrame>::reverse_iterator m_itTopOfStack;
};

